package com.googlecode.lightest.core

interface ITestRunner {

    /**
     * Returns the output directory
     */
    File getOutputDir()

    /**
     * Configures the runner by wiring together dependencies as specified by
     * the configuration file.
     *
     * @param configFile
     */
    void configure(File configFile)

    /**
     * Configures the runner by wiring together dependencies as specified by
     * the configuration text.
     *
     * @param configFile
     */
    void configure(String configText)

    /**
     * Sets the output directory
     *
     * @param dir
     */
    void setOutputDir(File dir)

    /**
     * Sets whether to refresh the report before each test is run. If set to
     * true, the report will be created in the directory that getOutputDir()
     * returns. Refreshing the report slows down test execution somewhat. For
     * longer running tests this will not be noticeable, while it may bog down
     * fast tests.
     *
     * @param refreshReport
     */
    void setRefreshReport(boolean refreshReport)

    /**
     * Executes the test suites represented by XML files, along with tests
     * represented as Groovy files, whose paths are provided as a parameter to
     * this method. The contextual class loader of the TestNG run is a
     * GroovyClassLoader that is aware of any task classpaths specified in the
     * Configuration.
     *
     * @param paths  paths to files that are either Lightest suite XML files,
     *               or Groovy scripts that are LightestTestCase's.
     */
    void run(List<String> paths)

}
